package com.wdd.owntool.adapter

import android.annotation.SuppressLint
import android.content.Context
import android.view.View
import android.view.ViewGroup
import com.wdd.libbase.base.OwnBaseAdapter
import com.wdd.owntool.R
import kotlinx.android.synthetic.main.adapter_main_str.view.*

/**
 *
 * @ProjectName:    OwnTool
 * @Package:        com.wdd.owntool.adapter
 * @ClassName:      MainAdapter
 * @Description:     java类作用描述
 * @Author:         王丹丹
 * @CreateDate:     2019/12/13 11:16
 * @UpdateUser:     更新者
 * @UpdateDate:     2019/12/13 11:16
 * @UpdateRemark:   更新说明
 * @Version:        1.0
 */
class MainAdapter(context: Context, datas: List<String>?) : OwnBaseAdapter<String>(context, datas) {


    @SuppressLint("ViewHolder")
    override fun getView(position: Int, convertView: View?, parent: ViewGroup?): View {
        var view = convertView
        if (view == null) {
            view = layoutInflater.inflate(R.layout.adapter_main_str, null)
        }
        view!!.text1.text = mDatas!![position]
        return view
    }

}